package com.haven.webrobotserver.service.impl;

import com.haven.webrobotserver.dao.mybatis.mapper.TestdataMapper;
import com.haven.webrobotserver.domain.Testdata;
import com.haven.webrobotserver.service.TestdataService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Required;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class TestdataServiceImpl implements TestdataService {

    @Autowired(required=false)
    private TestdataMapper testdataMapper;

    @Override
    public List<Testdata> getTestdataListByTestcaseid(int testcaseId) {

        return testdataMapper.getTestdataListByTestcaseId(testcaseId);
    }

    @Override
    public void updateTestdata(Testdata testdata) {
        testdataMapper.updateTestdata(testdata);
    }

    @Override
    public void newTestdata(Testdata testdata) {
        testdataMapper.newTestdata(testdata);
    }

    @Override
    public void deleteOne(int id) {
        testdataMapper.deleteOne(id);
    }
}
